Module WebmasterTools::Sitemappable::InstanceMethods
In: lib/webmaster_tools/sitemappable.rb

Methods

Public Instance methods

Determines what the changefreq element will be in the xml sitemap

[Source]

    # File lib/webmaster_tools/sitemappable.rb, line 97
97:       def sitemap_changefreq
98:         self.class.sitemap_changefreq
99:       end

Determines what host the url element use in the xml sitemap Useful to dynamically generate the correct subdomain for a record, for example

[Source]

     # File lib/webmaster_tools/sitemappable.rb, line 113
113:       def sitemap_host
114:         self.class.sitemap_host
115:       end

Determines what the lastmod element will be in the xml sitemap

[Source]

    # File lib/webmaster_tools/sitemappable.rb, line 92
92:       def sitemap_lastmod
93:         send(self.class.sitemap_lastmod_field)
94:       end

Determines what the url element be in the xml sitemap

[Source]

     # File lib/webmaster_tools/sitemappable.rb, line 107
107:       def sitemap_path
108:         "#{self.class.sitemap_path}/#{to_param}"
109:       end

Determines what the priority element be in the xml sitemap

[Source]

     # File lib/webmaster_tools/sitemappable.rb, line 102
102:       def sitemap_priority
103:         self.class.sitemap_priority
104:       end

Determines what protocol the url element use in the xml sitemap Useful if only certain records are https-protected

[Source]

     # File lib/webmaster_tools/sitemappable.rb, line 119
119:       def sitemap_protocol
120:         self.class.sitemap_protocol
121:       end

Turns this record into a sitemap node

[Source]

     # File lib/webmaster_tools/sitemappable.rb, line 124
124:       def to_sitemap_node
125:         WebmasterTools::Sitemaps::Node.new(:protocol => sitemap_protocol,
126:         :host => sitemap_host,
127:         :path => sitemap_path, 
128:         :lastmod => sitemap_lastmod, 
129:         :priority => sitemap_priority,
130:         :changefreq => sitemap_changefreq)
131:       end

[Validate]